﻿@model TraCuuThuatNgu.Models.ChangePasswordModel
@{
    ViewBag.Title = "Đổi mật khẩu";
    Layout = "~/Views/Shared/_Root.cshtml";
}

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
<div class="span span9-account">
    <div class="head">
        <div class="icm-user">
        </div>
        <h1>
            Thông tin tài khoản</h1>
        <div class="clear">
        </div>
    </div>
    <div class="block">
        <ul class="simple-menu">
            <li><a href="@Url.Content("~/Account/Info")">Thông tin tài khoản</a> </li>
            <li class="active"><a class="active" href="@Url.Content("~/Account/ChangePassword")">Đổi mật khẩu</a> </li>
            <li><a href="@Url.Content("~/AddContent")">Đóng góp của tôi</a> </li>
            <li><a href="@Url.Content("~/MyComments")">Bình luận của tôi</a> </li>
            <li><a href="@Url.Content("~/UserHistory")">Lịch sử tra cứu</a> </li>
            <li><a href="@Url.Content("~/Like")">Yêu thích</a> </li>
        </ul>
    </div>
</div>
<div class="span span8-account">
    <div class="head">
        <div class="icm-list">
        </div>
        <h1>
            Đổi mật khẩu</h1>
        <div class="clear">
        </div>
    </div>
    <div class="block">
        @*@using (Html.BeginForm())
        {
            @Html.ValidationSummary(true, "Password change was unsuccessful. Please correct the errors and try again.")
            <div>
                <fieldset>
                    <legend>Account Information</legend>
                    <div class="editor-label">
                        @Html.LabelFor(m => m.OldPassword)
                    </div>
                    <div class="editor-field">
                        @Html.PasswordFor(m => m.OldPassword)
                        @Html.ValidationMessageFor(m => m.OldPassword)
                    </div>
                    <div class="editor-label">
                        @Html.LabelFor(m => m.NewPassword)
                    </div>
                    <div class="editor-field">
                        @Html.PasswordFor(m => m.NewPassword)
                        @Html.ValidationMessageFor(m => m.NewPassword)
                    </div>
                    <div class="editor-label">
                        @Html.LabelFor(m => m.ConfirmPassword)
                    </div>
                    <div class="editor-field">
                        @Html.PasswordFor(m => m.ConfirmPassword)
                        @Html.ValidationMessageFor(m => m.ConfirmPassword)
                    </div>
                    <p>
                        <input type="submit" value="Change Password" />
                    </p>
                </fieldset>
            </div>
        }*@
        @using (Html.BeginForm())
        {               
            
            <div class="entry-form">
                <div class="editor">
                    <div class="editor-label">
                        Mật khẩu cũ
                    </div>
                    <div class="editor-field">
                         @Html.PasswordFor(m => m.OldPassword)<br />
                        @Html.ValidationMessageFor(m => m.OldPassword)
                    </div>
                    <div class="clear">
                    </div>
                </div>
                <div class="editor">
                    <div class="editor-label">
                       Mật khẩu mới
                    </div>
                    <div class="editor-field">
                       @Html.PasswordFor(m => m.NewPassword)<br />
                        @Html.ValidationMessageFor(m => m.NewPassword)
                    </div>
                    <div class="clear">
                    </div>
                </div>
                <div class="editor">
                    <div class="editor-label">
                        Nhập lại mật khẩu mới
                    </div>
                    <div class="editor-field">
                         @Html.PasswordFor(m => m.ConfirmPassword)<br />
                        @Html.ValidationMessageFor(m => m.ConfirmPassword)
                    </div>
                    <div class="clear">
                    </div>
                </div>                
                <div class="editor">
                    <div class="editor-label">
                    </div>
                    <div class="editor-field">
                        <input type="submit" class="btn" value="Cập nhật" />
                        
                        <span style='color:green'>@ViewBag.Success</span>
                        <span style='color:red'>@ViewBag.Fail</span>
                    </div>
                    <div class="clear">
                    </div>
                </div>
            </div>   
        }
    </div>
</div>
<div class="clear">
</div>
